package com.wtwd.campus.dao;

import com.wtwd.campus.entity.PersonalSetting;
import com.wtwd.campus.entity.SysUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.ArrayList;
import java.util.Map;


/**
 * @author mjy
 * @date 2021/06/08
 * @description
 */
@Mapper
public interface UserMapper {
    SysUser getSysUserByAccount(@Param("account") String account);

    int updateUserLastLoginTimeByUserId(@Param("userId") Integer userId, @Param("time") long time);

    SysUser getSysUserByUserId(Integer userId);

    Integer modifyPersonalSetting(@Param("userId") Integer userId,@Param("name") String name,@Param("logoUrl") String logoUrl);

    Integer getPersonalSetting(Integer userId);

    Integer addPersonalSetting(@Param("userId") Integer userId,@Param("name") String name,@Param("logoUrl") String logoUrl);

    PersonalSetting getOnePersonalSetting(@Param("userId") Integer userId);

    ArrayList<Integer> getSysUserIdListByOrgCode(@Param("orgCode") String orgCode);
}
